﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="CardEnter.aspx.cs" Inherits="User_PurchaseCardReg_CardEnter" %>

<%@ Register src="../../Controls/Head.ascx" tagname="Head" tagprefix="uc1" %>
<%@ Register src="../../Controls/Foot.ascx" tagname="Foot" tagprefix="uc2" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<script type="text/javascript" src="../../Scripts/jquery-1.2.6.min.js"></script>
<script type="text/javascript" src="../../Scripts/jquery.validate.js"></script>
<script type="text/javascript" src="../../Scripts/messages_cn.js"></script>
<link type="text/css" href="../../CSS/style.css" rel="Stylesheet" />
<link href="../../css/website1.css" rel="stylesheet" type="text/css" />
<link href="../../css/reg.css" rel="stylesheet" type="text/css" />
    <title>立言咨询平台 - 注册新用户</title>
        <script type="text/javascript">

            //        /*==========用户自定义方法==========*/


            //        /*==========事件绑定==========*/
            //        $(function() {

            //        });

            /*==========加载时执行的语句==========*/
            $(function() {
//                /* 设置默认属性 */ 
//                $.validator.setDefaults({
//                    submitHandler: function(form) { form.submit(); }
//                });    
                jQuery.validator.addMethod("isNumber", function(value, element) {
                    return this.optional(element) || /^(-?[0-9]*[.]*[0-9]{0,3})$/.test(value);
                }, "卡号只能数字");
                // 手机号码验证        
                $("#commentForm").validate(
           {
               errorClass: "error",
               ignoreTitle: true,
//               submitHandler: function(form) {
//                   //如果想提交表单, 需要使用form.submit()而不要使用$(form).submit()
//                   //alert("submitted!");
//                   form.submit();
//               },
               rules: {
                   realName: {
                       required: true,
                       isNumber: true
                   },
                   txt_password: {
                       required: true
                   }
               },
               messages: {
                   realName: { required: "卡号不能为空！" },
                   txt_password: { required: "请填写密码" }
               }
           });
            });        
    
    </script>
        <style type="text/css">
        /* form中显示文字的label */
        .slabel
        {
        	width:142px;
        	display: -moz-inline-box;
        	line-height: 1.8;
        	display: inline-block;
        	text-align:right;
        }
        /* 出错样式 */
        input.error, textarea.error
        {
        	border: solid 1px #CD0A0A;
        }
        label.error
        {
        	color:#CD0A0A;
        	margin-left:5px;
        }
        /* 深红色文字 */
        .textred
        {
        	color:#CD0A0A;
        }	
        </style>
</head>
<body>
    <form id="commentForm" runat="server">
    <div id="big">
        <uc1:Head ID="Head1" runat="server" />
        <div id="main" style="height:535px">
             <div id="r1"><div id="r11"><a href="#">&nbsp; &nbsp;立言注册</a></div></div>
             <div style="width:900px; height:368px;">
             <div style="border-top:8px #fff solid; line-height:8px;"></div>
             <div style=" text-align:left; color:#1C2B76; font-size:13px; font-weight:bold;">填写您购买的咨询卡卡号及密码</div>
             <div style="border-top:5px #1C2B76 solid; line-height:5px;"></div>
             <div style="height:85px;"></div>
             <div style="height:35px; font-weight:bold; font-size:13px;">输入咨询卡卡号：<asp:TextBox 
                     ID="realName" runat="server" 
                     Width="200px" BorderWidth="1px" ></asp:TextBox>
                     </div>
             <div style="border-top:20px #fff solid; line-height:20px;"></div>
             <div style="height:35px;font-weight:bold; font-size:13px;">输入咨询卡密码：<asp:TextBox 
                     ID="txt_password" runat="server" 
                     Width="200px" BorderWidth="1px" TextMode="Password"></asp:TextBox>
                     </div>
             <div style="border-top:20px #fff solid; line-height:20px;"></div>
             <div style="height:35px;font-weight:bold; font-size:13px;">
                 <asp:ImageButton ID="submit" runat="server" 
                     ImageUrl="~/Images/RegImg/querennext.jpg" onclick="submit_Click" />
                     </div>
             </div>
        </div>
        <uc2:Foot ID="Foot1" runat="server" />
    </div>
    </form>
</body>
</html>
